package io.github.bffcorreia.fole;

import androidx.annotation.Nullable;

class Preconditions
{
    static void checkArgument(boolean expression, @Nullable Object errorMessage)
    {
        if (!expression) {
            throw new IllegalArgumentException(String.valueOf(errorMessage));
        }
    }

    static void checkState(boolean expression, @Nullable Object errorMessage)
    {
        if (!expression) {
            throw new IllegalStateException(String.valueOf(errorMessage));
        }
    }
}
